﻿using Domain.Entity;
using Microsoft.EntityFrameworkCore.Metadata.Builders;
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace EfCore.Configers
{
    public class CQSKConfigers : IEntityTypeConfiguration<CQSK>
    {
        public void Configure(EntityTypeBuilder<CQSK> builder)
        {
            // 指定表名
            builder.ToTable("CQSK");

            // 配置主键
            builder.HasKey(e => e.QskId);

            // 配置自动增长列
            builder.Property(e => e.QskId).ValueGeneratedOnAdd();
        }
    }
}
